import { createApp } from "vue";
import { createPinia } from "pinia";
import piniaPersist from "pinia-plugin-persist";
import router from "./router";
import "./index.css";
import App from "./App.vue";
import "animate.css";
import VueLuckyCanvas from "@lucky-canvas/vue";

router.beforeEach((to, from, next) => {
    if (to.meta.title) {
        document.title = to.meta.title;
    }
    next();
});
let pinia = createPinia();
pinia.use(piniaPersist);
createApp(App).use(router).use(VueLuckyCanvas).use(pinia).mount("#app");
